
import React, { memo } from 'react'
import { useRoutes, Navigate } from "react-router-dom";
import Home from "../pages/Home/Home.js";
import About from "../pages/About/About.js";
import Life from "../pages/Life/Life.js";
import DetailOur from "../pages/DetailOur/DetailOur.js";
import DetailRole from "../pages/DetailRole/DetailRole.js";
import Relation from "../pages/Relation/Relation.js";
import DetailTutor from "../pages/DetailTutor/DetailTutor.js";
import SingleRole from "../pages/SingleRole/SingleRole.js"
import DetailCouple from "../pages/DetailCouple/DetailCouple.js"
import Sterile from "../pages/Sterile/Sterile.js"
import DetailStudent from "../pages/DetailStudent/DetailStudent.js"

const DefineRouters = memo(() => {
  const routes = useRoutes(
    [
      {
        path: '/Home',
        element: <Home />,
      },
      {
        path: '/DetailOur',
        element: <DetailOur />
      },
      {
        path: '/DetailRole',
        element: <DetailRole />
      },
      {
        path: '/About',
        element: <About />,
      },
      {
        path: '/Relation',
        element: <Relation />
      },
      {
        path: '/DetailTutor',
        element: <DetailTutor />
      },
      {
        path: '/SingleRole',
        element: <SingleRole />
      },
      {
        path: '/DetailCouple',
        element: <DetailCouple />
      },
      {
        path: '/Sterile',
        element: <Sterile />
      },
      {
        path: '/DetailStudent',
        element: <DetailStudent />
      },
      {
        path: '/Life',
        element: <Life />
      },
      {
        path: '/',
        element: <Navigate to='/Home'></Navigate>
      }
    ]
  )
  return routes
})

export default DefineRouters 